home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2001 May / SGI IRIX Base Documentation 2001 May.iso / usr / share / catman / p_man / cat3 / Xi / XGetDeviceKeyMapping.z / XGetDeviceKeyMapping
Encoding:
Text File  |  1998-10-30  |  10.3 KB  |  199 lines

  1.  
  2.  
  3.  
  4.      XXXXGGGGeeeettttDDDDeeeevvvviiiicccceeeeKKKKeeeeyyyyMMMMaaaappppppppiiiinnnngggg((((3333XXXX11111111))))XXXX VVVVeeeerrrrssssiiiioooonnnn 11111111 ((((RRRReeeelllleeeeaaaasssseeee 6666....3333))))XXXXGGGGeeeettttDDDDeeeevvvviiiicccceeeeKKKKeeeeyyyyMMMMaaaappppppppiiiinnnngggg((((3333XXXX11111111))))
  5.  
  6.  
  7.  
  8.      NNNNAAAAMMMMEEEE
  9.           XGetDeviceKeyMapping, XChangeDeviceKeyMapping - query or
  10.           change device key mappings
  11.  
  12.      SSSSYYYYNNNNTTTTAAAAXXXX
  13.           XXXXCCCChhhhaaaannnnggggeeeeDDDDeeeevvvviiiicccceeeeKKKKeeeeyyyyMMMMaaaappppppppiiiinnnngggg((((_d_i_s_p_l_a_y,,,, _d_e_v_i_c_e,,,, _f_i_r_s_t__k_e_y_c_o_d_e,,,,
  14.           _k_e_y_s_y_m_s__p_e_r__k_e_y_c_o_d_e,,,, _k_e_y_s_y_m_s,,,, _k_e_y_c_o_d_e__c_o_u_n_t))))
  15.                 DDDDiiiissssppppllllaaaayyyy ****_d_i_s_p_l_a_y;;;;
  16.                 XXXXDDDDeeeevvvviiiicccceeee ****_d_e_v_i_c_e;;;;
  17.                 iiiinnnntttt _f_i_r_s_t__k_e_y_c_o_d_e;;;;
  18.                 iiiinnnntttt _k_e_y_s_y_m_s__p_e_r__k_e_y_c_o_d_e;;;;
  19.                 KKKKeeeeyyyySSSSyyyymmmm ****_k_e_y_s_y_m_s;;;;
  20.                 iiiinnnntttt _k_e_y_c_o_d_e__c_o_u_n_t;;;;
  21.  
  22.           KKKKeeeeyyyySSSSyyyymmmm ****XXXXGGGGeeeettttDDDDeeeevvvviiiicccceeeeKKKKeeeeyyyyMMMMaaaappppppppiiiinnnngggg((((_d_i_s_p_l_a_y,,,, _d_e_v_i_c_e,,,, _f_i_r_s_t__k_e_y_c_o_d_e,,,, _k_e_y_c_o_d_e__c_o_u_n_t,,,,
  23.           _k_e_y_s_y_m_s__p_e_r__k_e_y_c_o_d_e__r_e_t_u_r_n))))
  24.                 DDDDiiiissssppppllllaaaayyyy ****_d_i_s_p_l_a_y;;;;
  25.                 XXXXDDDDeeeevvvviiiicccceeee ****_d_e_v_i_c_e;;;;
  26.                 KKKKeeeeyyyyCCCCooooddddeeee _f_i_r_s_t__k_e_y_c_o_d_e;;;;
  27.                 iiiinnnntttt _k_e_y_c_o_d_e__c_o_u_n_t;;;;
  28.                 iiiinnnntttt ****_k_e_y_s_y_m_s__p_e_r__k_e_y_c_o_d_e__r_e_t_u_r_n;;;;
  29.  
  30.  
  31.      AAAARRRRGGGGUUUUMMMMEEEENNNNTTTTSSSS
  32.           _d_i_s_p_l_a_y     Specifies the connection to the X server.
  33.  
  34.           _d_e_v_i_c_e      Specifies the device whose key mapping is to be
  35.                       queried or modified.
  36.  
  37.           _f_i_r_s_t__k_e_y_c_o_d_e
  38.                       Specifies the first KeyCode to be returned.
  39.  
  40.           _k_e_y_c_o_d_e__c_o_u_n_t
  41.                       Specifies the number of KeyCodes to be returned
  42.                       or modified.
  43.  
  44.           _k_e_y_s_y_m_s__p_e_r__k_e_y_c_o_d_e
  45.                       Specifies the number of KeySyms per KeyCode.
  46.  
  47.           _k_e_y_s_y_m_s__p_e_r__k_e_y_c_o_d_e__r_e_t_u_r_n
  48.                       Specifies the address of a variable into which
  49.                       the number of KeySyms per KeyCode will be
  50.                       returned.
  51.  
  52.           _k_e_y_s_y_m_s     Specifies the address of an array of KeySyms.
  53.  
  54.      DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  55.           For the specified device, the _X_G_e_t_D_e_v_i_c_e_K_e_y_M_a_p_p_i_n_g request
  56.           returns the symbols for the specified number of KeyCodes
  57.           starting with first_keycode.  The value specified in
  58.           first_keycode must be greater than or equal to min_keycode
  59.           as returned by _X_L_i_s_t_I_n_p_u_t_D_e_v_i_c_e_s, or a _B_a_d_V_a_l_u_e error
  60.  
  61.  
  62.  
  63.      Page 1                                          (printed 4/30/98)
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.      XXXXGGGGeeeettttDDDDeeeevvvviiiicccceeeeKKKKeeeeyyyyMMMMaaaappppppppiiiinnnngggg((((3333XXXX11111111))))XXXX VVVVeeeerrrrssssiiiioooonnnn 11111111 ((((RRRReeeelllleeeeaaaasssseeee 6666....3333))))XXXXGGGGeeeettttDDDDeeeevvvviiiicccceeeeKKKKeeeeyyyyMMMMaaaappppppppiiiinnnngggg((((3333XXXX11111111))))
  71.  
  72.  
  73.  
  74.           results.  In addition, the following expression must be less
  75.           than or equal to max_keycode as returned by
  76.           _X_L_i_s_t_I_n_p_u_t_D_e_v_i_c_e_s:
  77.  
  78.           first_keycode + keycode_count - 1
  79.  
  80.           If this is not the case, a _B_a_d_V_a_l_u_e error results. The
  81.           number of elements in the KeySyms list is:
  82.  
  83.           keycode_count * keysyms_per_keycode_return
  84.  
  85.           KeySym number N, counting from zero, for KeyCode K has the
  86.           following index in the list, counting from zero: (K -
  87.           first_code) * keysyms_per_code_return + N
  88.  
  89.           The X server arbitrarily chooses the
  90.           keysyms_per_keycode_return value to be large enough to
  91.           report all requested symbols. A special KeySym value of
  92.           _N_o_S_y_m_b_o_l is used to fill in unused elements for individual
  93.           KeyCodes.  To free the storage returned by
  94.           _X_G_e_t_D_e_v_i_c_e_K_e_y_M_a_p_p_i_n_g, use _X_F_r_e_e.
  95.  
  96.           If the specified device does not support input class keys, a
  97.           _B_a_d_M_a_t_c_h error will result.
  98.  
  99.           _X_G_e_t_D_e_v_i_c_e_K_e_y_M_a_p_p_i_n_g can generate a _B_a_d_D_e_v_i_c_e, _B_a_d_M_a_t_c_h, or
  100.           _B_a_d_V_a_l_u_e error.
  101.  
  102.           For the specified device, the _X_C_h_a_n_g_e_D_e_v_i_c_e_K_e_y_M_a_p_p_i_n_g
  103.           request defines the symbols for the specified number of
  104.           KeyCodes starting with first_keycode.  The symbols for
  105.           KeyCodes outside this range remain unchanged. The number of
  106.           elements in keysyms must be:
  107.  
  108.           num_codes * keysyms_per_keycode
  109.  
  110.           The specified first_keycode must be greater than or equal to
  111.           min_keycode returned by _X_L_i_s_t_I_n_p_u_t_D_e_v_i_c_e_s, or a _B_a_d_V_a_l_u_e
  112.           error results.  In addition, the following expression must
  113.           be less than or equal to max_keycode as returned by
  114.           _X_L_i_s_t_I_n_p_u_t_D_e_v_i_c_e_s, or a _B_a_d_V_a_l_u_e error results:
  115.  
  116.           first_keycode + num_codes - 1
  117.  
  118.           KeySym number N, counting from zero, for KeyCode K has the
  119.           following index in keysyms, counting from zero:
  120.  
  121.           (K - first_keycode) * keysyms_per_keycode + N
  122.  
  123.           The specified keysyms_per_keycode can be chosen arbitrarily
  124.           by the client to be large enough to hold all desired
  125.           symbols. A special KeySym value of _N_o_S_y_m_b_o_l should be used
  126.  
  127.  
  128.  
  129.      Page 2                                          (printed 4/30/98)
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.      XXXXGGGGeeeettttDDDDeeeevvvviiiicccceeeeKKKKeeeeyyyyMMMMaaaappppppppiiiinnnngggg((((3333XXXX11111111))))XXXX VVVVeeeerrrrssssiiiioooonnnn 11111111 ((((RRRReeeelllleeeeaaaasssseeee 6666....3333))))XXXXGGGGeeeettttDDDDeeeevvvviiiicccceeeeKKKKeeeeyyyyMMMMaaaappppppppiiiinnnngggg((((3333XXXX11111111))))
  137.  
  138.  
  139.  
  140.           to fill in unused elements for individual KeyCodes. It is
  141.           legal for _N_o_S_y_m_b_o_l to appear in nontrailing positions of the
  142.           effective list for a KeyCode.  _X_C_h_a_n_g_e_D_e_v_i_c_e_K_e_y_M_a_p_p_i_n_g
  143.           generates a _D_e_v_i_c_e_M_a_p_p_i_n_g_N_o_t_i_f_y event that is sent to all
  144.           clients that have selected that type of event.
  145.  
  146.           There is no requirement that the X server interpret this
  147.           mapping. It is merely stored for reading and writing by
  148.           clients.
  149.  
  150.           If the specified device does not support input class keys, a
  151.           _B_a_d_M_a_t_c_h error results.
  152.  
  153.           _X_C_h_a_n_g_e_D_e_v_i_c_e_K_e_y_M_a_p_p_i_n_g can generate a _B_a_d_D_e_v_i_c_e, _B_a_d_M_a_t_c_h,
  154.           _B_a_d_A_l_l_o_c, or _B_a_d_V_a_l_u_e  error.
  155.  
  156.      DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
  157.           _B_a_d_D_e_v_i_c_e   An invalid device was specified.  The specified
  158.                       device does not exist or has not been opened by
  159.                       this client via _X_O_p_e_n_I_n_p_u_t_D_e_v_i_c_e.  This error
  160.                       may also occur if the specified device is the X
  161.                       keyboard or X pointer device.
  162.  
  163.           _B_a_d_M_a_t_c_h    This error may occur if an _X_G_e_t_D_e_v_i_c_e_K_e_y_M_a_p_p_i_n_g
  164.                       or _X_C_h_a_n_g_e_D_e_v_i_c_e_K_e_y_M_a_p_p_i_n_g request was made
  165.                       specifying a device that has no keys.
  166.  
  167.           _B_a_d_V_a_l_u_e    Some numeric value falls outside the range of
  168.                       values accepted by the request.  Unless a
  169.                       specific range is specified for an argument, the
  170.                       full range defined by the argument's type is
  171.                       accepted.  Any argument defined as a set of
  172.                       alternatives can generate this error.
  173.  
  174.           _B_a_d_A_l_l_o_c    The server failed to allocate the requested
  175.                       resource or server memory.
  176.  
  177.      SSSSEEEEEEEE AAAALLLLSSSSOOOO
  178.           XSetDeviceButtonMapping(3X11)
  179.           XSetDeviceModifierMapping(3X11)
  180.           _P_r_o_g_r_a_m_m_i_n_g _w_i_t_h _X_l_i_b
  181.  
  182.  
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.      Page 3                                          (printed 4/30/98)
  196.  
  197.  
  198.  
  199.